<?php
/**
 * Created by PhpStorm.
 * User: zhongyb
 * Date: 2016/6/6
 * Time: 14:30
 */
namespace common\repositories\common;

use common\repositories\BaseRepository;
use common\entities\common\MyscrmErpserviceaddresstemplateEntity;
use Yii;

class MyscrmErpserviceaddresstemplateRepository extends BaseRepository {

    /**
     * 获取模板
     * @param bool $initOnOrgCreated 是否在创建租户时初始化
     * @return array|\yii\db\ActiveRecord[]
     */
    public function getErpserviceaddresstemplateList($initOnOrgCreated)
    {
        return MyscrmErpserviceaddresstemplateEntity::find()
            ->where(['initOnOrgCreated'=>$initOnOrgCreated])
            ->asArray()
            ->all();
    }

}